package com.ht.safe.entity;

import javax.persistence.*;
import java.util.List;

/**
 * 门控制器
 *
 * @author: 薄成文 13-8-2 上午10:43
 * To change this template use File | Settings | File Templates.
 */
public class DoorController {
    private String name;
    private String type;
    private Boolean used;

    /**
     * 所属主控制器
     */
    @ManyToOne(fetch= FetchType.LAZY)
    @JoinColumn(name="master_controller_id")
    private MasterController masterController;

    @OneToMany(cascade = CascadeType.REMOVE, mappedBy = "doorController")
    private List<Door> doors;

}
